<html>
<head>
<title></title>
<STYLE>
.toolbartable
{
	background: #889CD5;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
}
.toolbartext
{
	font-size: 12px;
	font-family: Verdana,Tahoma;
	font-weight:bolder;
	color: Black;
}
.toolbarselect
{
	font-size: 11px;
	font-family: Verdana,Tahoma;
	font-weight:normal;
}
.toolbarbutton
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    BACKGROUND-COLOR: #cccccc;
    color:Black;
    border-color:Silver;
}
.toolbartitleheading
{
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
	text-align:right;
}
.toolbartitle
{
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
	text-align:right;
	font-weight:bolder;
}


.toolboxtable
{
	background:  #889CD5;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
}
.toolboxinternaltable
{
	background:  #889CD5;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
}
.toolboxheading
{
	background: black;
	font-size: 12px;
	font-family: Verdana, Tahoma;
	color: White;
	font-weight:bolder;
	text-align:center;
}
.toolboxcolumn
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    BACKGROUND-COLOR:  #889CD5;
    color:white;
    border-color:White;	
    border-top: 1px ridge #C6B36C;
	border-right: 1px ridge #413400;
	border-bottom: 1px ridge #413400;
	border-left: 1px ridge #C6B36C;
}
.toolboxbuttons
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    BACKGROUND-COLOR: #889CD5;
    color:white;   
    border-color:White;
}
.toolboxparent
{
	background:  #C4D2FB;
	font-size: 11px;
	font-family: Verdana, Tahoma;
	color: black;
	font-weight:bolder;
	text-align:center;
}
.toolboxparentbevell
{
	background:  #889CD5;
	font-size: 11px;
	font-family: Verdana, Tahoma;
	color: White;
	font-weight:bolder;
	text-align:center;
	border-top: 1px ridge #C6B36C;
	border-right: 1px ridge #413400;
	border-bottom: 1px ridge #413400;
	border-left: 1px ridge #C6B36C;
}


.imagetable
{
	background: #C4D2FB;
}
.imageiframe
{
	background: #FFFF66;
}



.propertiesboxtable
{
	background: #889CD5;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
}
.propertiesboxheading
{
	background: Black;
	font-size: 12px;
	font-family: Verdana, Tahoma;
	color: White;
	font-weight:bolder;
	text-align:center;
}
.propertiesboxactionselect
{
	font-size: 11px;
	font-family: Verdana,Tahoma;
	font-weight:normal;
}
.propertiesboxbuttons
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    BACKGROUND-COLOR: #cccccc;
    color:black;
    border-color:silver;	
}
.propertiesboxpropertytable
{
	background: Silver;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;	
}
.propertiesboxpropertyextraspace
{
	background:  #C4D2FB;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
}
.propertiesboxpropertybuttonstable
{
	background:  #C4D2FB;
	font-size: 15px;
	font-family: Verdana,Tahoma;
	color: Black;
}
.propertiesboxinput
{
	FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    text-decoration: none;
}
.propertiesboxselect
{
	font-size: 11px;
	font-family: Verdana,Tahoma;
	font-weight:normal;
}
.propertiesboxpropertytitle
{
	font-size: 11px;
	font-family: Verdana,Tahoma;
	font-weight:normal;
	background: #C4D2FB;
}
.propertiesboxinputs
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
	border: 0px #737373 solid;
	text-decoration: none;
}
.propertiesboxinputstable
{
	background: White;
	font-size: 11px;
	font-family: Verdana,Tahoma;
	color: Black;	
}
.propertiesboxinputbutton
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    BACKGROUND-COLOR: #889CD5;
    color:White;
    border-color:White;	
}



TD
{
    FONT-SIZE: 10px;
    FONT-FAMILY: Verdana,Tahoma
}
A
{
    COLOR: navy
}
.linkinputs
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    text-decoration: none;
    border: 1px #737373 solid;
    width: 200px
}
.returninputs
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    text-decoration: none;
    border: 1px #737373 solid;
    width: 150px
}
.inputs
{
    FONT-SIZE: 12px;
    FONT-FAMILY: Verdana,Tahoma;
    text-decoration: none;
    border: 1px #737373 solid
}
.lockedinputs
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
    BACKGROUND-COLOR: #DBEAF5;
}
.buttons
{
    FONT-SIZE: 11px;
        FONT-FAMILY: Verdana,Tahoma;
        BACKGROUND-COLOR: #cccccc;
        color:black;
    border-color:silver;
}
.pageheader
{
    FONT-WEIGHT: bold;
    FONT-SIZE: 12px;
    FONT-FAMILY: Verdana,Tahoma
}
.properties
{
    FONT-SIZE: 11px;
    COLOR: maroon;
    FONT-FAMILY: Verdana,Tahoma
}
.list
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana, Tahoma
}
.propertyselected
{
    BACKGROUND-COLOR: midnightblue
}
.propertytableinputs
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
	border: 1 solid white;
	text-decoration: none;
}
.propertypage
{
	background-color : #93BEE2;
}
.controlbg
{
	background-color : #93BEE2;
}
.gridtableinputs
{
    FONT-SIZE: 11px;
    FONT-FAMILY: Verdana,Tahoma;
	border: 1 solid white;
}
.gridanchor
{
    FONT-SIZE: 10px;
    FONT-FAMILY: Verdana,Tahoma;
	text-decoration:none;
}
</STYLE>

<script language="javascript">

	function BindService(){
		ServiceSelBox = document.getElementsByTagName("select")["WebServiceList"];
		SelValue  = ServiceSelBox.value;
		
		if(SelValue == ""){
			alert("Please select a Web Service");
			return;
		}
		document.frm_service._mode.value = 'ListMethods';
		document.frm_service._serviceID.value = ServiceSelBox.value;
		
		document.frm_service.btnBind.disabled = true;
		
		document.frm_service.submit();
	}
	
	function DeleteService(){
		ServiceSelBox = document.getElementsByTagName("select")["WebServiceList"];
		SelValue  = ServiceSelBox.value;
		
		if(SelValue == ""){
			alert("Please select a Web Service");
			return;
		}
		
		if(confirm("Are you sure you want to delete this web service reference ?")){
			document.frm_service._mode.value = 'DeleteService';
			document.frm_service._serviceID.value = ServiceSelBox.value;
			document.frm_service.btnDelete.disabled = true;
			document.frm_service.submit();
		}
	}
	
	function AddReference(){
		SelName		= document.frm_service.serviceName.value;
		ServiceURL  = document.frm_service.serviceURL.value;
		
		if(SelName == ""){
			alert("Please enter Web Service Name");
			document.frm_service.serviceName.focus();
			return;
		}
		if(ServiceURL == ""){
			alert("Please enter a Web Service URL");
			document.frm_service.serviceURL.focus();
			return;
		}
		
		document.frm_service.btnAddRef.disabled = true;
		
		document.frm_service._mode.value = 'AddReference';
		document.frm_service.submit();
	}

   function populateValues(source,destn,txtBox){
	  eval("var oselect3 = document.frm_service."+source+".value");
	  eval("document.frm_service."+destn+".options.length=0");

	  if(oselect3 != "Value"){
		eval("var nodeLength = "+oselect3 +"DI.XMLDocument.documentElement.childNodes.length");
		eval("document.getElementById('"+txtBox+"').style.display = 'none'");
		eval("document.frm_service."+txtBox+".value = ''");
		eval("document.getElementById('"+destn+"').style.display = 'block'");
		
		for(i=0;i < nodeLength;i++){
	 		eval("document.frm_service."+destn+".options["+i+"] = new Option("+ oselect3 +"DI.XMLDocument.documentElement.childNodes("+i+").text,"+  oselect3 +"DI.XMLDocument.documentElement.childNodes("+i+").text)");
		}
	  }
	  else{
		eval("document.getElementById('"+txtBox+"').style.display = 'block'");
		eval("document.getElementById('"+destn+"').style.display = 'none'");
	  }
	}

	function loadpg(){
		alert();
		document.frames["frmProgressBar"].document.location = "http://localhost/ngwebapp/pb/progressbar.aspx";
	}
</script>

	</head>
	<body topmargin="0" leftmargin="0" >
	<xml id="VariableDI">
		<%#VariableXML%> 
	</xml>
	<xml id="ContentDI">
		 <%#ContentXML%>
	</xml>
		<form name="frm_service" method="post">
			<table width="100%" border="0" height="100%" cellpadding="5" cellspacing="10">
				<tr>
					<td align="left" width="50%" height="50%">
						Choose a Web Service from the list below :<p>
							<select id="WebServiceList" size="10" name="sel_webservice" class=gridtableinputs>
								<%#WebServiceList%>
							</select></p>
				<input type="button" class="buttons" NAME="btnDelete" value='Delete Webservice' onclick="DeleteService()">
					&nbsp;&nbsp;&nbsp;&nbsp;<input type="button" class="buttons" NAME="btnBind" value='Bind Webservice' onclick="BindService()">
					</td>
				</tr>
				<tr >
					<td height=1 bgcolor=#808080>						</td>
				</tr>
			
				<tr>
					<td align="left">
						<TABLE id="Table1" align="left" cellSpacing="0" cellPadding="3" width="80%"	border="0">
							<TR>
								<TD height=40> WebService Name </TD>
								<TD><INPUT type="text" size="30" name="serviceName" ></TD>
							</TR>
							<TR>
								<TD height=40> WebService URL </TD>
								<TD><input type="text" name="serviceURL" size="50"></TD>
							</TR>
							<TR>
								<TD> Login Name </TD>
								<TD height=40 > <input type="text" name="LoginName" size="25"></TD>
							</TR>
							<TR>
								<TD> Password </TD>
								<TD height=40> <input type="text" name="Password" size="25"> </TD>
							</TR>
							<TR>
								<TD> Domain Name </TD>
								<TD height=40> <input type="text" name="DomainName" size="25">	</TD>
								 
							</TR>
							<TR>
								<TD>&nbsp;</TD>
								<TD>&nbsp;</TD>
								 
							</TR>							
							<TR>
								<TD> </TD>
								<TD><input type="button" class="buttons" value='Add New Web Reference' onclick="AddReference()" ID="Button1" NAME="btnAddRef"></TD>
								 
							</TR>
						</TABLE>
						&nbsp;	<br>&nbsp;<br>
						
					&nbsp;<br><input type="hidden" name="_mode"> <input type="hidden" name="_serviceID">
					</td>
				</tr>
<!--			<tr>
				<td>
					  <iframe id="frmProgressBar" name="frmProgressBar" width="100%" height="400" src="about:blank" border="0" frameborder="0"></iframe>
				</td>
				</tr> -->
			</table>
			
		</form>
	</body>
</html>
